const React = require('react');

class TodoItem extends React.Component {
    constructor(props) {
        super(props);
    }

    render() {
        return (
            <div className="view">
                <input
                    className="toggle"
                    type="checkbox"
                />
                <label>
                    {this.props.title}
                </label>
                <input type='button'
                    onClick={this.props.onDestroy}
                    value='删除' />
            </div>
        )
    }
}


module.exports = TodoItem;